package bean;

/**
 * @author 李夏
 * @version 1.0
 */

public class PageRequest {
    //当前页
    private Integer currentPage = 1;
    //每页显示个数
    private Integer pageSize = 10;
    //从多少条记录开始查询
    private Integer offset;

    public PageRequest() {
    }

    public Integer getOffset() {
        return (currentPage-1)*pageSize;
    }

    public Integer getCurrentPage() {
        return currentPage;
    }

    public void setCurrentPage(Integer currentPage) {
        this.currentPage = currentPage;
    }


    public Integer getPageSize() {
        return pageSize;
    }

    public void setPageSize(Integer pageSize) {
        this.pageSize = pageSize;
    }

    public void setOffset(Integer offset) {
        this.offset = offset;
    }
}
